Programming with QuickTime VR

| Previous | Chapter contents | Chapter top | Section top | Next |

QTVRNudge

You can use the QTVRNudge function to turn one step in a particular direction and display the new view.

OSErr QTVRNudge (QTVRInstance qtvr, QTVRNudgeControl direction);
qtvr
An instance of a QuickTime VR movie.
direction
The direction of the nudge. See "Nudge Directions" for a description of the values you can pass in this parameter.
function result
A result code.

DESCRIPTION

The QTVRNudge function adjusts the current view of the movie specified by the qtvr parameter as indicated by the direction parameter. In particular, QTVRNudge turns one step in the indicated direction and displays the new view.

For example, to move to the next view that is right and up from the current view, set the direction parameter to kQTVRUpRight (that is, /4 radians, or 45 degrees). Any value of the direction parameter that is not predefined is mapped to the closest defined value. For objects, if no view is located at the adjacent object view defined by the nudge direction and wrapping is off in the desired direction, then QTVRNudge remains at the current view and returns the result code constraintReachedErr .

For objects, QTVRNudge is useful for changing to an adjacent view without having to know the new pan and tilt angles.

The direction of the nudge is affected by the current control settings. See "Control Settings" for more information.

SEE ALSO

Use QTVRSetPanAngle (link) and QTVRSetTiltAngle (link) to move to a new view specified using pan and tilt angles.


© 1997 Apple Computer, Inc.

| Previous | Chapter contents | Chapter top | Section top | Next |